import 'package:flutter/material.dart';
import 'package:wk_weather/utils/MyLogTool.dart';

/// app 导航监听
class AppNavigatorObserver extends NavigatorObserver {
  @override
  void didPush(Route<dynamic> route, Route<dynamic> previousRoute) {
    if (route.settings.name != null) {
      weatherPrint("进入页面: ${route.settings.name}");
    }
  }

  @override
  void didPop(Route<dynamic> route, Route<dynamic> previousRoute) {
    if (route.settings.name != null) {
      weatherPrint("退出页面: ${route.settings.name}");
    }
  }
}


